<!doctype html>
<html>

	<head>
		<meta charset="utf-8">
		<title>首页</title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<!--标准mui.css-->
		<link rel="stylesheet" href="css/mui.min.css">
		<link rel="stylesheet" type="text/css" href="css/style.css" />
		
		<!-- 引用animate.css -->
		<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/4.1.1/animate.min.css"/>
		
		<!--App自定义的css-->
		<link rel="stylesheet" type="text/css" href="css/app.css" />
		<style type="text/css">
			body {
				background: #F2F2F2;
			}

			#app {
				padding-top: 44px;
			}

			.top {
				width: 100%;
				height: 21.9rem;
				background: #fff;
				padding: 0.8rem 1.8rem 2rem;
			}

			.middle {
				margin-bottom: 5rem;
			}

			.mui-slider {
				height: 13.5rem;
			}

			.content-list {
				padding-top: 1.3rem;
				/* padding-bottom: 1.2rem; */
				width: 100%;
				background: #fff;
				margin-top: 1.2rem;
			}

			.content-list::after {
				content: '';
				clear: both;
				display: block;
			}

			.content-list-title {
				font-size: 1.5rem;
				font-family: PingFang SC;
				font-weight: 600;
				line-height: 1.6rem;
				color: #333333;
				padding-left: 4.8rem;
				position: relative;
				border-bottom: 0.1rem solid #E3E3E3;
				padding-bottom: 1.2rem;
			}
			.content-list-title p {
				display: inline-block;
				margin: 0;
				padding: 0;
				color: #333;
			}
			.content-list-title p i {
				font-family: cursive;
			}
			.title-first p i {
				font-style: normal;
				display:inline-block;
					vertical-align:bottom;
				-webkit-animation-name:fontSizeUp1;
				animation-name:fontSizeUp1;
				-webkit-animation-duration:3s;
				animation-duration:3s;
				-webkit-animation-timing-function:steps(1,end);
				animation-timing-function:steps(1,end);
				-webkit-animation-fill-mode:none;
				animation-fill-mode:none;
				-webkit-animation-iteration-count:infinite;
				animation-iteration-count:infinite;
				-webkit-transform-origin:50% 75%;
				transform-origin:50% 75%;
			}
			.title-first p i:nth-of-type(1) {
				-webkit-animation-delay:0s;
				animation-delay:0s;
			}
			.title-first p i:nth-of-type(2) {
				-webkit-animation-delay:0.5s;
				animation-delay:0.5s;
			}
			.title-first p i:nth-of-type(3) {
				-webkit-animation-delay:1s;
				animation-delay:1s;
			}
			.title-first p i:nth-of-type(4) {
				-webkit-animation-delay:1.5s;
				animation-delay:1.5s;
			}
			.title-first p i:nth-of-type(5) {
				-webkit-animation-delay:2s;
				animation-delay:2s;
			}
			.title-first p i:nth-of-type(6) {
				-webkit-animation-delay:2.5s;
				animation-delay:2.5s;
			}
			
			.title-second p i {
				font-style: normal;
				display:inline-block;
					vertical-align:bottom;
				-webkit-animation-name:fontSizeUp1;
				animation-name:fontSizeUp1;
				-webkit-animation-duration:2s;
				animation-duration:2s;
				-webkit-animation-timing-function:steps(1,end);
				animation-timing-function:steps(1,end);
				-webkit-animation-fill-mode:none;
				animation-fill-mode:none;
				-webkit-animation-iteration-count:infinite;
				animation-iteration-count:infinite;
				-webkit-transform-origin:50% 75%;
				transform-origin:50% 75%;
			}
			.title-second p i:nth-of-type(1) {
				-webkit-animation-delay:0s;
				animation-delay:0s;
			}
			.title-second p i:nth-of-type(2) {
				-webkit-animation-delay:0.5s;
				animation-delay:0.5s;
			}
			.title-second p i:nth-of-type(3) {
				-webkit-animation-delay:1s;
				animation-delay:1s;
			}
			
			.title-third p i {
				font-style: normal;
				display:inline-block;
					vertical-align:bottom;
				-webkit-animation-name:fontSizeUp1;
				animation-name:fontSizeUp1;
				-webkit-animation-duration:2s;
				animation-duration:2s;
				-webkit-animation-timing-function:steps(1,end);
				animation-timing-function:steps(1,end);
				-webkit-animation-fill-mode:none;
				animation-fill-mode:none;
				-webkit-animation-iteration-count:infinite;
				animation-iteration-count:infinite;
				-webkit-transform-origin:50% 75%;
				transform-origin:50% 75%;
			}
			.title-third p i:nth-of-type(1) {
				-webkit-animation-delay:0s;
				animation-delay:0s;
			}
			.title-third p i:nth-of-type(2) {
				-webkit-animation-delay:0.5s;
				animation-delay:0.5s;
			}
			.title-third p i:nth-of-type(3) {
				-webkit-animation-delay:1s;
				animation-delay:1s;
			}
			.title-third p i:nth-of-type(4) {
				-webkit-animation-delay:1.5s;
				animation-delay:1.5s;
			}
			.title-forth p i {
				font-style: normal;
				display:inline-block;
					vertical-align:bottom;
				-webkit-animation-name:fontSizeUp1;
				animation-name:fontSizeUp1;
				-webkit-animation-duration:2s;
				animation-duration:2s;
				-webkit-animation-timing-function:steps(1,end);
				animation-timing-function:steps(1,end);
				-webkit-animation-fill-mode:none;
				animation-fill-mode:none;
				-webkit-animation-iteration-count:infinite;
				animation-iteration-count:infinite;
				-webkit-transform-origin:50% 75%;
				transform-origin:50% 75%;
			}
			.title-forth p i:nth-of-type(1) {
				-webkit-animation-delay:0s;
				animation-delay:0s;
			}
			.title-forth p i:nth-of-type(2) {
				-webkit-animation-delay:0.5s;
				animation-delay:0.5s;
			}
			.title-forth p i:nth-of-type(3) {
				-webkit-animation-delay:1s;
				animation-delay:1s;
			}
			.title-forth p i:nth-of-type(4) {
				-webkit-animation-delay:1.5s;
				animation-delay:1.5s;
			}
			@-webkit-keyframes fontSizeUp1 {
				0% {
				-webkit-transform:scale(1.25);
				transform:scale(1.25);
			}
			7%,100% {
				-webkit-transform:scale(1);
				transform:scale(1);
			}
			}
			@keyframes fontSizeUp1 {
				0% {
				-webkit-transform:scale(1.25);
				transform:scale(1.25);
			}
			7%,100% {
				-webkit-transform:scale(1);
				transform:scale(1);
			}
			}
			.title-first .fontSizeUp1,.title-second .fontSizeUp1,.title-third .fontSizeUp1,.title-forth .fontSizeUp1 {
				-webkit-animation-name:fontSizeUp1;
				animation-name:fontSizeUp1;
			}
			.content-list-title a {
				font-size: 1.2rem;
				font-family: PingFang SC;
				font-weight: 400;
				color: #999999;
				float: right;
				margin-right: 1.8rem;
			}

			.content-list-title::before {
				content: '';
				display: inline-block;
				width: 2rem;
				height: 2rem;
				position: absolute;
				left: 1.8rem;
				top: 50%;
				margin-top: -1.6rem;
			}

			.title-first::before {
				background: url(images/title01.png) no-repeat;
				background-size: 100% 100%;
			}

			.title-second::before {
				background: url(images/title02.png) no-repeat;
				background-size: 100% 100%;
			}

			.title-third::before {
				background: url(images/title03.png) no-repeat;
				background-size: 100% 100%;
			}

			.title-forth::before {
				background: url(images/title04.png) no-repeat;
				background-size: 100% 100%;
			}

			.newFile .content-list-area {
				padding: 1.8rem 1.8rem 0;
			}

			.newFile .list {
				width: 49%;
				height: 14.4rem;
				float: left;
				margin-bottom: 2.1rem;
			}

			.newFile .list img {
				width: 100%;
				height: 9.5rem;
			}

			.newFile .list h3 {
				width: 100%;
				font-size: 1.4rem;
				font-family: PingFangSC;
				font-weight: 400;
				color: #333333;
				overflow: hidden;
				white-space: nowrap;
				text-overflow: ellipsis;
			}

			.newFile .content-list-area .list:nth-child(2n) {
				margin-left: 2%;
			}

			.takebyHand .content-list-area .list {
				display: flex;
				justify-content: space-around;
				padding: 1.4rem 1.8rem 1.1rem;
				border-bottom: 0.1rem solid #E2E2E2;
			}

			.takebyHand .content-list-area .list:last-child {
				border-bottom: none;
			}

			.takebyHand .content-list-area .list .word {
				width: 21rem;
			}

			.takebyHand .content-list-area .list h3 {
				font-size: 1.5rem;
				font-family: PingFangSC;
				font-weight: 400;
				color: #333333;
				height: 4rem;
				line-height: 2rem;
				display: -webkit-box;
				overflow: hidden;
				text-overflow: ellipsis;
				-webkit-box-orient: vertical;
				-webkit-line-clamp: 2;
				white-space: normal;
			}

			.takebyHand .content-list-area .list p {
				font-size: 1.2rem;
				font-family: PingFangSC;
				font-weight: 400;
				line-height: 1.6rem;
				color: #999999;
			}

			.takebyHand .content-list-area .list .picture img,.takebyHand .content-list-area .list .picture video {
				width: 11.1rem;
				height: 7rem;
			}

			.peixun .content-list-area .list .list-area {
				padding: 2rem 1.8rem 1.3rem;
				border-bottom: 0.1rem solid #E2E2E2;
			}

			.peixun .content-list-area .list .user {
				font-size: 1.6rem;
				font-family: PingFangSC;
				font-weight: 400;
				color: #666666;
			}

			.peixun .content-list-area .list .user img {
				width: 3rem;
				height: 3rem;
				vertical-align: middle;
				margin-right: 1rem;
			}

			.peixun .content-list-area .list h3 {
				font-size: 1.7rem;
				font-family: PingFangSC;
				font-weight: 400;
				color: #333333;
				height: 4rem;
				line-height: 2rem;
				display: -webkit-box;
				overflow: hidden;
				text-overflow: ellipsis;
				-webkit-box-orient: vertical;
				-webkit-line-clamp: 2;
				white-space: normal;
			}

			.peixun .content-list-area .list .pictures img {
				width: 32%;
				height: 10.9rem;
			}

			.peixun .content-list-area .list .operate {
				width: 100%;
				line-height: 50px;
				display: block;
				justify-content: space-around;
				align-items: center;
				font-size: 1.2rem;
				font-family: PingFang SC;
				font-weight: 500;
				color: #333333;
			}

			.peixun .content-list-area .list .orangeWords {
				color: #FC6A02;
			}

			.peixun .content-list-area .list .operate img {
				width: 1.5rem;
				height: 1.5rem;
				vertical-align: text-top;
				margin-right: 0.4rem;
			}

			.peixun .content-list-area .list .operate .operate-list {
				width: 50%;
				text-align: center;
				position: relative;
				float: left;
				
			}

			.peixun .content-list-area .list .operate .operate-list:first-child::after {
				content: '';
				display: inline-block;
				width: 0.1rem;
				height: 1.8rem;
				background: #E3E3E3;
				position: absolute;
				right: 0;
				top: 50%;
				margin-top: -0.9rem;
			}

			.activityCenter .content-list-area .list {
				padding: 1.8rem;
				border-bottom: 0.1rem solid #E2E2E2;
			}

			.activityCenter .content-list-area .list:last-child {
				border-bottom: none;
			}

			.activityCenter .content-list-area .list img {
				width: 100%;
				/* height: 13.5rem; */
				max-height: 25.1rem;
			}

			.activityCenter .content-list-area .list p {
				font-size: 1.7rem;
				font-family: PingFangSC;
				font-weight: 400;
				color: #333333;
				margin-top: 10px;
			}

			/* 图片预览代码 */
			.mui-preview-image.mui-fullscreen {
				position: fixed;
				z-index: 20;
				background-color: #000;
				height: auto;
			}

			.mui-preview-header,
			.mui-preview-footer {
				position: absolute;
				width: 100%;
				left: 0;
				z-index: 10;
			}

			.mui-preview-header {
				height: 44px;
				top: 0;
			}

			.mui-preview-footer {
				height: 50px;
				bottom: 0px;
			}

			.mui-preview-header .mui-preview-indicator {
				display: block;
				line-height: 25px;
				color: #fff;
				text-align: center;
				margin: 15px auto 4;
				width: 70px;
				background-color: rgba(0, 0, 0, 0.4);
				border-radius: 12px;
				font-size: 16px;
			}

			.mui-preview-image {
				display: none;
				-webkit-animation-duration: 0.5s;
				animation-duration: 0.5s;
				-webkit-animation-fill-mode: both;
				animation-fill-mode: both;
			}

			.mui-preview-image.mui-preview-in {
				-webkit-animation-name: fadeIn;
				animation-name: fadeIn;
			}

			.mui-preview-image.mui-preview-out {
				background: none;
				-webkit-animation-name: fadeOut;
				animation-name: fadeOut;
			}

			.mui-preview-image.mui-preview-out .mui-preview-header,
			.mui-preview-image.mui-preview-out .mui-preview-footer {
				display: none;
			}

			.mui-zoom-scroller {
				position: absolute;
				display: -webkit-box;
				display: -webkit-flex;
				display: flex;
				-webkit-box-align: center;
				-webkit-align-items: center;
				align-items: center;
				-webkit-box-pack: center;
				-webkit-justify-content: center;
				justify-content: center;
				left: 0;
				right: 0;
				bottom: 0;
				top: 0;
				width: 100%;
				height: 100%;
				margin: 0;
				-webkit-backface-visibility: hidden;
			}

			.mui-zoom {
				-webkit-transform-style: preserve-3d;
				transform-style: preserve-3d;
			}

			.mui-slider .mui-slider-group .mui-slider-item img {
				width: auto;
				height: auto;
				max-width: 100%;
				max-height: 100%;
			}

			.mui-android-4-1 .mui-slider .mui-slider-group .mui-slider-item img {
				width: 100%;
			}

			.mui-android-4-1 .mui-slider.mui-preview-image .mui-slider-group .mui-slider-item {
				display: inline-table;
			}

			.mui-android-4-1 .mui-slider.mui-preview-image .mui-zoom-scroller img {
				display: table-cell;
				vertical-align: middle;
			}

			.mui-preview-loading {
				position: absolute;
				width: 100%;
				height: 100%;
				top: 0;
				left: 0;
				display: none;
			}

			.mui-preview-loading.mui-active {
				display: block;
			}

			.mui-preview-loading .mui-spinner-white {
				position: absolute;
				top: 50%;
				left: 50%;
				margin-left: -25px;
				margin-top: -25px;
				height: 50px;
				width: 50px;
			}

			.mui-preview-image img.mui-transitioning {
				-webkit-transition: -webkit-transform 0.5s ease, opacity 0.5s ease;
				transition: transform 0.5s ease, opacity 0.5s ease;
			}

			@-webkit-keyframes fadeIn {
				0% {
					opacity: 0;
				}

				100% {
					opacity: 1;
				}
			}

			@keyframes fadeIn {
				0% {
					opacity: 0;
				}

				100% {
					opacity: 1;
				}
			}

			@-webkit-keyframes fadeOut {
				0% {
					opacity: 1;
				}

				100% {
					opacity: 0;
				}
			}

			@keyframes fadeOut {
				0% {
					opacity: 1;
				}

				100% {
					opacity: 0;
				}
			}

			p img {
				max-width: 100%;
				height: auto;
			}
		</style>
	</head>

	<body>
		<header class="mui-bar mui-bar-nav">
			<a class="mui-action-back mui-icon mui-icon-closeempty mui-pull-left"></a>
			<h1 class="mui-title">首页</h1>
		</header>
		<div id="app" v-cloak>
			<!-- 搜索&&轮播图 -->
			<div class="top">
				<div class="search mui-input-row mui-search">
					<input type="search" v-model="keyword" placeholder="搜索热门关键词" @keyup.enter="search">
				</div>
				<div id="slider" class="mui-slider">
					<div class="mui-slider-group mui-slider-loop">
						<!-- 额外增加的一个节点(循环轮播：第一个节点是最后一张轮播) -->
						<div class="mui-slider-item mui-slider-item-duplicate">
							<a href="#">
								<img :src="bannerlist[0]">
							</a>
						</div>
						<!-- 第一张 -->
						<div class="mui-slider-item" v-for="item in bannerlist">
							<a href="#">
								<img :src="item">
							</a>
						</div>
						<!-- 额外增加的一个节点(循环轮播：最后一个节点是第一张轮播) -->
						<div class="mui-slider-item mui-slider-item-duplicate">
							<a href="#">
								<img :src="bannerlist[bannerlist.length - 1]">
							</a>
						</div>
					</div>
					<div class="mui-slider-indicator">
						<div class="mui-indicator" :class="index == 0?'mui-active':''" v-for="item,index in bannerlist"></div>
					</div>
				</div>
			</div>

			<!-- 内容区域 -->
			<div class="middle">

				<!-- 最新原创投稿 -->
				<div class="content-list newFile">
					<div class="content-list-title title-first">
						<p>
							<i>最</i>
							<i>新</i>
							<i>原</i>
							<i>创</i>
							<i>投</i>
							<i>稿</i>
						</p>
						<a href="#" @click="goUrl('list_01.html')">查看更多</a>
					</div>
					<div class="content-list-area">
						<div class="list" v-for="item,index of originNews" @click="goDetail(item)" v-if="index < 4">
							<img :src="item.images" data-preview-src="" :data-preview-group="item.id">
							<h3>{{item.title}}</h3>
							<p>{{item.department_name}}</p>
						</div>
					</div>
				</div>
				<!-- 随手拍 -->
				<div class="content-list takebyHand">
					<div class="content-list-title title-second">
						<p>
							<i>随</i>
							<i>手</i>
							<i>拍</i>
						</p>
						<a href="#" @click="goUrl('list_02.html')">查看更多</a>
					</div>
					<div class="content-list-area">
						<div class="list" v-for="item,index in handPhotos" @click="goDetail(item)" v-if="index < 4">
							<div class="word">
								<h3>{{item.title}}</h3>
								<p>{{item.user_info.nickname}}</p>
							</div>
							<div class="picture">
								<template v-if="item.videofile">
									<video width="100%" height=""  :src="item.videofile" controls style="margin-bottom: 0.9375rem;">
										当前浏览器不支持 video直接播放
									</video>
								</template>
								<template v-else>
									<img :src="item.images[0]" alt="" data-preview-src="" :data-preview-group="item.id">
								</template>
							</div>
						</div>
					</div>
				</div>

				<!-- 培训拼团 -->
				<div class="content-list peixun">
					<div class="content-list-title title-third">
						<p>
							<i>培</i>
							<i>训</i>
							<i>拼</i>
							<i>团</i>
						</p>
						<a href="#" @click="goUrl('list_03.html')">查看更多</a>
					</div>
					<div class="content-list-area">
						<div class="list" v-for="item,index in list3"  v-if="index < 4">
							<div class="list-area" @click="goActiveDetail(item)">
								<div class="user">
									<img :src="baseUrl+item.department_image" alt="">{{item.department_name}}
								</div>
								<h3>{{item.title}}</h3>
								<div class="pictures">
									<img :src="it" v-for="it in item.images" data-preview-src="" :data-preview-group="item.id">
								</div>
							</div>
							<div class="operate">
								<div class="operate-list" :class="item.is_votes == 1?'orangeWords':''" @click="votes(item)">
									<img :src="item.is_votes == 1?'images/d01.png':'images/operate01.png'" alt="">{{item.votesnumber}}
								</div>
								<div class="operate-list orangeWords">
									<span class="heart " :class="item.is_great == 1?'heartAnimation':''" :rel="item.is_great == 1?'unlike':'like'" :newsId="item.id"></span>
								</div>
							</div>
						</div>
					</div>
				</div>

				<!-- 活动集锦 -->
				<div class="content-list activityCenter">
					<div class="content-list-title title-forth">
						<p>
							<i>活</i>
							<i>动</i>
							<i>集</i>
							<i>锦</i>
						</p>
						<a href="#" @click="goUrl('list_04.html')">查看更多</a>
					</div>
					<div class="content-list-area">
						<div class="list" v-for="item,index in list4" @click="goActiveDetail(item)"  v-if="index < 4">
							<img :src="it" v-for="it,inx in item.images" data-preview-src="" :data-preview-group="item.id" v-if="inx < 1">
							<p>{{item.title}}</p>
						</div>
					</div>
				</div>
			</div>
		</div>
		<nav class="mui-bar mui-bar-tab bottom-tab">
			<a class="mui-tab-item mui-active" href="index.html">
				<span class="mui-icon"><img src="images/tabbar_04.png"></span>
				<span class="mui-tab-label">首页</span>
			</a>
			<a class="mui-tab-item" href="list_02.html">
				<span class="mui-icon"><img src="images/tabbar_02.png"></span>
				<span class="mui-tab-label">随手拍</span>
			</a>
			<a class="mui-tab-item" href="my.html">
				<span class="mui-icon"><img src="images/tabbar_03.png"></span>
				<span class="mui-tab-label">个人中心</span>
			</a>
		</nav>

		<script src="js/mui.js"></script>
		<script src="js/vue.js"></script>
		<script src="js/mui.zoom.js"></script>
		<script src="js/mui.previewimage.js"></script>
		<script src="js/jquery-1.11.0.min.js" type="text/javascript"></script>
		<script type="text/javascript">
			var app = new Vue({
				el: '#app',
				data: {
					originNews: [],
					handPhotos: [],
					group: [],
					keyword: "",
					list3: [],
					list4: [],
					baseUrl: baseUrl,
					bannerlist: [],
					userinfo:{},
				},
				methods: {
					// 获取原创投稿
					getOriginNews() {
						var that = this;
						var params = {
							type: 2,
							keyword: this.keyword
						}
						$get("/api/news/getlist", params, function(res) {
							for (var i = 0; i < res.length; i++) {
								res[i].images = res[i].images[0]
							}
							that.originNews = res;
						})
					},
					//  获取随手拍(线索汇总)
					getHandPhotos() {
						var that = this;
						var params = {
							type: 4,
							keyword: this.keyword
						}
						$get("/api/news/getlist", params, function(res) {
							that.handPhotos = res;
						})
					},
					//  获取培训拼团
					getList3() {
						var that = this;
						var params = {
							type: 5,
							keyword: this.keyword,
							user_id:this.userinfo.user_id || ""
						}
						$get("/api/news/getactivitylist", params, function(res) {
							that.list3 = res;
						})
					},
					//  获取活动集锦
					getList4() {
						var that = this;
						var params = {
							type: 4,
							keyword: this.keyword,
							user_id:this.userinfo.user_id || ""
						}
						$get("/api/news/getactivitylist", params, function(res) {
							that.list4 = res;
						})
					},
					search: function() {
						this.getOriginNews()
						this.getHandPhotos()
						this.getList3()
						this.getList4()
					},
					getBanner: function() {
						$get("/api/news/getbannerlist", {}, function(res) {
							app.bannerlist = res;
							app.$nextTick(function() {
								var slider = mui("#slider");
								slider.slider({
									interval: 3000
								});
							})

						})
					},
					goUrl: function(url) {
						mui.openWindow(url)
					},
					goDetail: function(item) {
						mui.openWindow("detail.html?id=" + item.id)
					},
					goActiveDetail: function(item, newType) {
						mui.openWindow("active_detail.html?id=" + item.id)
					},
					votes: function(item) {
						if(item.is_votes == 1){return}
						if(!app.userinfo.user_id){
							mui.toast("请先登录之后再点赞", {
								duration: 'short',
								type: 'div'
							})
							return
						}
						$post("/api/news/getactivityoperation", {type:0,id:item.id,user_id:app.userinfo.user_id}, function(res) {
							item.is_votes = 1;
							item.votesnumber += 1;
							mui.toast("投票成功", {
								duration: 'short',
								type: 'div'
							})
						})
					},
				},
				created: function() {

				},
				mounted: function() {
					if (localStorage.getItem("userinfo")) {
						this.userinfo = JSON.parse(localStorage.getItem("userinfo"))
					}
					mui.init()
					this.getOriginNews();
					this.getHandPhotos();
					this.getList3()
					this.getList4()
					mui.previewImage();
					this.getBanner()
				}
			})

			$('body').on("click", '.heart', function() {
				$(this).css("background-position", "")
				var D = $(this).attr("rel");
				var newsId = $(this).attr("newsId");
				var $this = $(this);
				if (D === 'like') {
					if(!app.userinfo.user_id){
						mui.toast("请先登录之后再点赞", {
							duration: 'short',
							type: 'div'
						})
						return
					}
					$post("/api/news/getactivityoperation", {type:1,id:newsId,user_id:app.userinfo.user_id}, function(res) {
						$this.addClass("heartAnimation").attr("rel", "unlike");
					})
				} 
				// else {
				// 	$(this).removeClass("heartAnimation").attr("rel", "like");
				// 	$(this).css("background-position", "left");
				// }
				
				

			});
		</script>
	</body>

</html>
